package pacman.entries.pacman.ml.features;

import pacman.game.Constants.GHOST;
import pacman.game.Game;

public class GhostIsEdibleFeature extends FeatureExtractor {

	GHOST m_Ghost;
	
	public GhostIsEdibleFeature(float ghostFloat) {
		super();
		m_Ghost = GHOST.values()[(int)ghostFloat];
	}
	
	@Override
	protected float Extract(Game game) {
		
		if (game.isGhostEdible(m_Ghost))
			return 1.0f;
		else
			return 0.0f;
	}

}
